﻿@{
    Layout = "~/Views/Shared/_LayoutAdminPage.cshtml";
}
@section header{
    <style>


        /** 应用快捷块样式 */
        .console-app-group {
            padding: 16px;
            border-radius: 4px;
            text-align: center;
            background-color: #fff;
            cursor: pointer;
            display: block;
        }

            .console-app-group .console-app-icon {
                width: 32px;
                height: 32px;
                line-height: 32px;
                margin-bottom: 6px;
                display: inline-block;
                -webkit-box-sizing: border-box;
                -moz-box-sizing: border-box;
                box-sizing: border-box;
                font-size: 32px;
                color: #69c0ff;
            }

            .console-app-group:hover {
                box-shadow: 0 0 15px rgba(0, 0, 0, .08);
            }

        /** //应用快捷块样式 */

        /** 小组成员 */
        .console-user-group {
            position: relative;
            padding: 10px 0 10px 60px;
        }

            .console-user-group .console-user-group-head {
                width: 32px;
                height: 32px;
                position: absolute;
                top: 50%;
                left: 12px;
                margin-top: -16px;
                border-radius: 50%;
            }

            .console-user-group .layui-badge {
                position: absolute;
                top: 50%;
                right: 8px;
                margin-top: -10px;
            }

            .console-user-group .console-user-group-name {
                line-height: 1.2;
            }

            .console-user-group .console-user-group-desc {
                color: #8c8c8c;
                line-height: 1;
                font-size: 12px;
                margin-top: 5px;
            }

        /** 卡片轮播图样式 */
        .admin-carousel .layui-carousel-ind {
            position: absolute;
            top: -41px;
            text-align: right;
        }

            .admin-carousel .layui-carousel-ind ul {
                background: 0 0;
            }

            .admin-carousel .layui-carousel-ind li {
                background-color: #e2e2e2;
            }

                .admin-carousel .layui-carousel-ind li.layui-this {
                    background-color: #999;
                }

        /** 广告位轮播图 */
        .admin-news .layui-carousel-ind {
            height: 45px;
        }

        .admin-news a {
            display: block;
            line-height: 70px;
            text-align: center;
        }

        /** 最新动态时间线 */
        .layui-timeline-dynamic .layui-timeline-item {
            padding-bottom: 0;
        }

            .layui-timeline-dynamic .layui-timeline-item:before {
                top: 16px;
            }

        .layui-timeline-dynamic .layui-timeline-axis {
            width: 9px;
            height: 9px;
            left: 1px;
            top: 7px;
            background-color: #cbd0db;
        }

            .layui-timeline-dynamic .layui-timeline-axis.active {
                background-color: #0c64eb;
                box-shadow: 0 0 0 2px rgba(12, 100, 235, .3);
            }

        .dynamic-card-body {
            box-sizing: border-box;
            overflow: hidden;
        }

            .dynamic-card-body:hover {
                overflow-y: auto;
                padding-right: 9px;
            }

        /** 优先级徽章 */
        .layui-badge-priority {
            border-radius: 50%;
            width: 20px;
            height: 20px;
            padding: 0;
            line-height: 18px;
            border-width: 2px;
            font-weight: 600;
        }
    </style>

}

<!-- 正文开始 -->
<div class="layui-fluid ew-console-wrapper">
    <div class="layui-row layui-col-space15"  data-step="1" data-intro="欢迎使用NetCoreGeneralMvc！这里显示最新统计信息！" >
        <div class="layui-col-xs12 layui-col-sm6 layui-col-md3">
            <div class="layui-card">
                <div class="layui-card-header">
                    访问量<span class="layui-badge layui-badge-green pull-right">日</span>
                </div>
                <div class="layui-card-body">
                    <p class="lay-big-font">25,848</p>
                    <p>总访问量<span class="pull-right">280 万</span></p>
                </div>
            </div>
        </div>
        <div class="layui-col-xs12 layui-col-sm6 layui-col-md3">
            <div class="layui-card">
                <div class="layui-card-header">
                    销售额<span class="layui-badge layui-badge-blue pull-right">月</span>
                </div>
                <div class="layui-card-body">
                    <p class="lay-big-font"><span style="font-size: 26px;line-height: 1;">¥</span>12,000</p>
                    <p>总销售额<span class="pull-right">68 万</span></p>
                </div>
            </div>
        </div>
        <div class="layui-col-xs12 layui-col-sm6 layui-col-md3">
            <div class="layui-card">
                <div class="layui-card-header">
                    订单量<span class="layui-badge layui-badge-red pull-right">周</span>
                </div>
                <div class="layui-card-body">
                    <p class="lay-big-font">1,680</p>
                    <p>转化率<span class="pull-right">60%</span></p>
                </div>
            </div>
        </div>
        <div class="layui-col-xs12 layui-col-sm6 layui-col-md3">
            <div class="layui-card">
                <div class="layui-card-header">
                    新增用户
                    <span class="icon-text pull-right" lay-tips="指标说明" lay-direction="4" lay-offset="5px,5px">
                        <i class="layui-icon layui-icon-tips"></i>
                    </span>
                </div>
                <div class="layui-card-body">
                    <p class="lay-big-font">128 <span style="font-size: 24px;line-height: 1;">位</span></p>
                    <p>总用户<span class="pull-right">10800 人</span></p>
                </div>
            </div>
        </div>
    </div>
    <!-- 快捷方式 -->
    <div class="layui-row layui-col-space15">
        <div class="layui-col-sm6" style="padding-bottom: 0;">
            <div class="layui-row layui-col-space15" data-step="2" data-intro="这里为菜单栏，为您快速引导！" >
                <div class="layui-col-xs6 layui-col-sm3">
                    <div class="console-app-group" ew-href="page/system/user.html" ew-title="用户管理">
                        <i class="console-app-icon layui-icon layui-icon-group"
                           style="font-size: 26px;padding-top: 3px;margin-right: 6px;"></i>
                        <div class="console-app-name">用户</div>
                    </div>
                </div>
                <div class="layui-col-xs6 layui-col-sm3">
                    <div class="console-app-group">
                        <i class="console-app-icon layui-icon layui-icon-chart" style="color: #95de64;"></i>
                        <div class="console-app-name">分析</div>
                    </div>
                </div>
                <div class="layui-col-xs6 layui-col-sm3">
                    <div class="console-app-group">
                        <i class="console-app-icon layui-icon layui-icon-cart" style="color: #ff9c6e;"></i>
                        <div class="console-app-name">商品</div>
                    </div>
                </div>
                <div class="layui-col-xs6 layui-col-sm3">
                    <div class="console-app-group">
                        <i class="console-app-icon layui-icon layui-icon-form"
                           style="color: #b37feb;font-size: 30px;"></i>
                        <div class="console-app-name">订单</div>
                    </div>
                </div>
            </div>
        </div>
        <div class="layui-col-sm6" style="padding-bottom: 0;">
            <div class="layui-row layui-col-space15">
                <div class="layui-col-xs6 layui-col-sm3">
                    <div class="console-app-group">
                        <i class="console-app-icon layui-icon layui-icon-layer"
                           style="color: #ffd666;font-size: 34px;"></i>
                        <div class="console-app-name">票据</div>
                    </div>
                </div>
                <div class="layui-col-xs6 layui-col-sm3">
                    <div class="console-app-group">
                        <i class="console-app-icon layui-icon layui-icon-email"
                           style="color: #5cdbd3;font-size: 36px;"></i>
                        <div class="console-app-name">消息</div>
                    </div>
                </div>
                <div class="layui-col-xs6 layui-col-sm3">
                    <div class="console-app-group">
                        <i class="console-app-icon layui-icon layui-icon-note"
                           style="color: #ff85c0;font-size: 28px;"></i>
                        <div class="console-app-name">标签</div>
                    </div>
                </div>
                <div class="layui-col-xs6 layui-col-sm3">
                    <div class="console-app-group">
                        <i class="console-app-icon layui-icon layui-icon-slider" style="color: #ffc069;"></i>
                        <div class="console-app-name">配置</div>
                    </div>
                </div>
            </div>
        </div>
    </div>

    <div class="layui-row layui-col-space15">
        <div class="layui-col-md8 layui-col-sm6">
            <div class="layui-row layui-col-space15">
                <div class="layui-col-md6">
                    <div class="layui-card">
                        <div class="layui-card-header">最新动态</div>
                        <div class="layui-card-body dynamic-card-body mini-bar" style="height: 265px;">
                            <ul class="layui-timeline layui-timeline-dynamic">
                                <li class="layui-timeline-item">
                                    <i class="layui-icon layui-timeline-axis"></i>
                                    <div class="layui-timeline-content layui-text">
                                        <div class="layui-timeline-title">
                                            研发经理 指派了任务 陪客户吃饭
                                            <span class="pull-right">14:30 </span>
                                        </div>
                                    </div>
                                </li>
                                <li class="layui-timeline-item">
                                    <i class="layui-icon layui-timeline-axis active"></i>
                                    <div class="layui-timeline-content layui-text">
                                        <div class="layui-timeline-title">
                                            测试组长 提交了bug 代码错误
                                            <span class="pull-right">14:00 </span>
                                        </div>
                                    </div>
                                </li>
                                <li class="layui-timeline-item">
                                    <i class="layui-icon layui-timeline-axis"></i>
                                    <div class="layui-timeline-content layui-text">
                                        <div class="layui-timeline-title">
                                            管理员 登录了系统
                                            <span class="pull-right">13:30 </span>
                                        </div>
                                    </div>
                                </li>
                                <li class="layui-timeline-item">
                                    <i class="layui-icon layui-timeline-axis active"></i>
                                    <div class="layui-timeline-content layui-text">
                                        <div class="layui-timeline-title">
                                            开发一 解决了bug 代码错误
                                            <span class="pull-right">11:30 </span>
                                        </div>
                                    </div>
                                </li>
                                <li class="layui-timeline-item">
                                    <i class="layui-icon layui-timeline-axis active"></i>
                                    <div class="layui-timeline-content layui-text">
                                        <div class="layui-timeline-title">
                                            测试一 创建了用例 用户登录
                                            <span class="pull-right">11:00 </span>
                                        </div>
                                    </div>
                                </li>
                                <li class="layui-timeline-item">
                                    <i class="layui-icon layui-timeline-axis"></i>
                                    <div class="layui-timeline-content layui-text">
                                        <div class="layui-timeline-title">
                                            开发二 退出了系统
                                            <span class="pull-right">10:30 </span>
                                        </div>
                                    </div>
                                </li>
                                <li class="layui-timeline-item">
                                    <i class="layui-icon layui-timeline-axis"></i>
                                    <div class="layui-timeline-content layui-text">
                                        <div class="layui-timeline-title">
                                            研发经理 指派了任务 修改大bug
                                            <span class="pull-right">10:00 </span>
                                        </div>
                                    </div>
                                </li>
                                <li class="layui-timeline-item">
                                    <i class="layui-icon layui-timeline-axis"></i>
                                    <div class="layui-timeline-content layui-text">
                                        <div class="layui-timeline-title">
                                            研发经理 指派了任务 修改小bug
                                            <span class="pull-right">09:30 </span>
                                        </div>
                                    </div>
                                </li>
                                <li class="layui-timeline-item">
                                    <i class="layui-icon layui-timeline-axis active"></i>
                                    <div class="layui-timeline-content layui-text">
                                        <div class="layui-timeline-title">
                                            研发经理 指派了任务 修改小bug
                                            <span class="pull-right">09:00 </span>
                                        </div>
                                    </div>
                                </li>
                                <li class="layui-timeline-item">
                                    <i class="layui-icon layui-timeline-axis"></i>
                                    <div class="layui-timeline-content layui-text">
                                        <div class="layui-timeline-title">
                                            管理员 登录了系统
                                            <span class="pull-right">08:30 </span>
                                        </div>
                                    </div>
                                </li>
                            </ul>
                        </div>
                    </div>
                </div>
                <div class="layui-col-md6">
                    <div class="layui-card">
                        <div class="layui-card-header">我的任务</div>
                        <div class="layui-card-body">
                            <table class="layui-table" lay-skin="line">
                                <colgroup>
                                    <col width="80" />
                                    <col />
                                    <col width="80" />
                                </colgroup>
                                <thead>
                                    <tr>
                                        <td align="center">优先级</td>
                                        <td>任务名称</td>
                                        <td align="center">状态</td>
                                    </tr>
                                </thead>
                                <tbody>
                                    <tr>
                                        <td align="center">
                                            <span class="layui-badge layui-badge-red layui-badge-priority">1</span>
                                        </td>
                                        <td><span class="layui-text"><a>参加股东大会</a></span></td>
                                        <td align="center"><span class="text-warning">未开始</span></td>
                                    </tr>
                                    <tr>
                                        <td align="center">
                                            <span class="layui-badge layui-badge-yellow layui-badge-priority">2</span>
                                        </td>
                                        <td><span class="layui-text"><a>陪客户吃饭</a></span></td>
                                        <td align="center"><span class="text-warning">未开始</span></td>
                                    </tr>
                                    <tr>
                                        <td align="center">
                                            <span class="layui-badge layui-badge-blue layui-badge-priority">3</span>
                                        </td>
                                        <td><span class="layui-text"><a>项目开发</a></span></td>
                                        <td align="center"><span class="text-success">进行中</span></td>
                                    </tr>
                                    <tr>
                                        <td align="center">
                                            <span class="layui-badge layui-badge-blue layui-badge-priority">3</span>
                                        </td>
                                        <td><span class="layui-text"><a>修改大bug</a></span></td>
                                        <td align="center">
                                            <del class="text-muted">已完成</del>
                                        </td>
                                    </tr>
                                    <tr>
                                        <td align="center">
                                            <span class="layui-badge layui-badge-blue layui-badge-priority">3</span>
                                        </td>
                                        <td><span class="layui-text"><a>修改小bug</a></span></td>
                                        <td align="center">
                                            <del class="text-muted">已完成</del>
                                        </td>
                                    </tr>
                                </tbody>
                            </table>
                        </div>
                    </div>
                </div>
                <div class="layui-col-md12">
                    <div class="layui-card">
                        <div class="layui-card-header">项目进度</div>
                        <div class="layui-card-body">
                            <table class="layui-table" lay-skin="line">
                                <colgroup>
                                    <col width="40" />
                                    <col />
                                    <col />
                                    <col />
                                    <col />
                                    <col width="160" />
                                </colgroup>
                                <thead>
                                    <tr>
                                        <td></td>
                                        <td>项目名称</td>
                                        <td align="center">开始时间</td>
                                        <td align="center">截至时间</td>
                                        <td align="center">状态</td>
                                        <td align="center">进度</td>
                                    </tr>
                                </thead>
                                <tbody>
                                    <tr>
                                        <td>1</td>
                                        <td><span class="layui-text"><a>仓库管理系统</a></span></td>
                                        <td align="center">2020-03-01</td>
                                        <td align="center">2020-06-01</td>
                                        <td align="center"><span class="text-success">进行中</span></td>
                                        <td>
                                            <div class="layui-progress" lay-showPercent="yes">
                                                <div class="layui-progress-bar" lay-percent="30%"></div>
                                            </div>
                                        </td>
                                    </tr>
                                    <tr>
                                        <td>2</td>
                                        <td><span class="layui-text"><a>档案管理系统</a></span></td>
                                        <td align="center">2020-03-01</td>
                                        <td align="center">2020-08-01</td>
                                        <td align="center"><span class="text-success">进行中</span></td>
                                        <td>
                                            <div class="layui-progress" lay-showPercent="yes">
                                                <div class="layui-progress-bar" lay-percent="10%"></div>
                                            </div>
                                        </td>
                                    </tr>
                                    <tr>
                                        <td>3</td>
                                        <td><span class="layui-text"><a>后台管理系统</a></span></td>
                                        <td align="center">2020-01-01</td>
                                        <td align="center">2020-05-01</td>
                                        <td align="center"><span class="text-danger">已延期</span></td>
                                        <td>
                                            <div class="layui-progress" lay-showPercent="yes">
                                                <div class="layui-progress-bar" lay-percent="60%"></div>
                                            </div>
                                        </td>
                                    </tr>
                                    <tr>
                                        <td>4</td>
                                        <td><span class="layui-text"><a>粮情监测系统</a></span></td>
                                        <td align="center">2020-06-01</td>
                                        <td align="center">2020-10-01</td>
                                        <td align="center"><span class="text-warning">未开始</span></td>
                                        <td>
                                            <div class="layui-progress" lay-showPercent="yes">
                                                <div class="layui-progress-bar" lay-percent="0%"></div>
                                            </div>
                                        </td>
                                    </tr>
                                    <tr>
                                        <td>5</td>
                                        <td><span class="layui-text"><a>项目00000001</a></span></td>
                                        <td align="center">2020-01-01</td>
                                        <td align="center">2020-04-01</td>
                                        <td align="center"><span class="text-muted">已完成</span></td>
                                        <td>
                                            <div class="layui-progress" lay-showPercent="yes">
                                                <div class="layui-progress-bar" lay-percent="90%"></div>
                                            </div>
                                        </td>
                                    </tr>
                                    <tr>
                                        <td>6</td>
                                        <td><span class="layui-text"><a>项目00000002</a></span></td>
                                        <td align="center">2020-01-01</td>
                                        <td align="center">2020-03-01</td>
                                        <td align="center"><span class="text-muted">已完成</span></td>
                                        <td>
                                            <div class="layui-progress" lay-showPercent="yes">
                                                <div class="layui-progress-bar" lay-percent="100%"></div>
                                            </div>
                                        </td>
                                    </tr>
                                </tbody>
                            </table>
                        </div>
                    </div>
                </div>
            </div>
        </div>
        <div class="layui-col-md4 layui-col-sm6">
            <div class="layui-card" data-step="3" data-intro="这里显示您的系统信息及版权信息！">
                <div class="layui-card-header">版本信息</div>
                <div class="layui-card-body">
                    <table class="layui-table layui-text">
                        <colgroup>
                            <col width="90">
                            <col>
                        </colgroup>
                        <tbody>
                            <script type="text/html" ew-tpl>
                                <tr>
                                    <td>当前版本</td>
                                    <td>
                                        v1.0.0 &emsp; <a href="https://gitee.com/liuprogramme/NetCoreGeneralMvc" target="_blank">更新日志</a>
                                    </td>
                                </tr>
                            </script>
                            <tr>
                                <td>系统名称</td>
                                <td>@ViewBag.OSDescription</td>
                            </tr>
                            <tr>
                                <td>进程架构</td>
                                <td>@ViewBag.ProcessArchitecture</td>
                            </tr>
                            <tr>
                                <td>.NetCore版本</td>
                                <td>@ViewBag.FrameworkDescription</td>
                            </tr>
                            <tr>
                                <td>已使用物理内存</td>
                                <td>@ViewBag.UsedMem kb</td>
                            </tr>
                            <tr>
                                <td>运行时间</td>
                                <td>@ViewBag.UsedCPUTime ms</td>
                            </tr>
                            <tr>
                                <td>处理器数</td>
                                <td>@ViewBag.ProcessorCount</td>
                            </tr>
                            
                            <tr>
                                <td>主要特色</td>
                                <td>简约 / 易上手</td>
                            </tr>
                            <tr>
                                <td>获取渠道</td>
                                <td>
                                    <a href="https://gitee.com/liuprogramme/NetCoreGeneralMvc" class="layui-btn layui-btn-sm layui-btn-danger"
                                       target="_blank">获取授权</a>
                                    <a href="https://gitee.com/liuprogramme/NetCoreGeneralMvc" target="_blank" class="layui-btn layui-btn-sm">立即下载</a>
                                </td>
                            </tr>
                        </tbody>
                    </table>
                </div>
            </div>
            <div class="layui-card" style="display:none">
                <div class="layui-card-header">小组成员</div>
                <div class="layui-card-body">
                    <div class="console-user-group">
                        <img src="../../assets/images/head.jpg" class="console-user-group-head" alt="" />
                        <div class="console-user-group-name">周星星</div>
                        <div class="console-user-group-desc">产品负责人</div>
                        <span class="layui-badge layui-badge-green">在线</span>
                    </div>
                    <div class="console-user-group">
                        <img src="../../assets/images/head.jpg" class="console-user-group-head" alt="" />
                        <div class="console-user-group-name">周星星</div>
                        <div class="console-user-group-desc">项目负责人</div>
                        <span class="layui-badge layui-badge-green">在线</span>
                    </div>
                    <div class="console-user-group">
                        <img src="../../assets/images/head.jpg" class="console-user-group-head" alt="" />
                        <div class="console-user-group-name">周星星</div>
                        <div class="console-user-group-desc">产品负责人</div>
                        <span class="layui-badge layui-badge-red">离线</span>
                    </div>
                    <div class="console-user-group">
                        <img src="../../assets/images/head.jpg" class="console-user-group-head" alt="" />
                        <div class="console-user-group-name">周星星</div>
                        <div class="console-user-group-desc">测试负责人</div>
                        <span class="layui-badge layui-badge-red">离线</span>
                    </div>
                </div>
            </div>
            <div class="layui-card">
                <div class="layui-card-header">友情链接</div>
                <div class="layui-card-body">
                    <div class="layui-carousel admin-carousel admin-news" id="workplaceNewsCarousel">
                        <div carousel-item>
                            <div>
                                <a href="https://gitee.com/liuprogramme/NetCoreGeneralMvc" target="_blank"
                                   style="color:#fff;background-color: #009688;background-image: linear-gradient(to right,#009688,#5fb878);">
                                    NetCoreGeneralMvc
                                </a>
                            </div>
                            <div>
                                <a href="https://gitee.com/liuprogramme/NetCoreGeneralMvc" target="_blank"
                                   style="color:#fff;background-color: #009fde;background-image: linear-gradient(to right,#009fde,#00beff);">
                                    NetCoreGeneralMvc
                                </a>
                            </div>
                            <div>
                                <a href="https://gitee.com/liuprogramme/NetCoreGeneralMvc" target="_blank"
                                   style="color:#fff;background-color: #34363f;background-image: linear-gradient(to right,#34363f,#676c7c);">
                                    NetCoreGeneralMvc官方社区
                                </a>
                            </div>
                        </div>
                    </div>
                </div>
            </div>
        </div>
    </div>
</div>


<script>
    layui.use(['layer', 'carousel', 'element', 'introJs'], function () {
        var $ = layui.jquery;
        var layer = layui.layer;
        var carousel = layui.carousel;
        var device = layui.device();
        var introJs = layui.introJs;

        // 渲染轮播
        carousel.render({
            elem: '#workplaceNewsCarousel',
            width: '100%',
            height: '70px',
            arrow: 'none',
            autoplay: true,
            trigger: device.ios || device.android ? 'click' : 'hover',
            anim: 'fade'
        });
        
        
        const foowwLocalStorage = {
            set: function (key, value, ttl_ms) {
                var data = { value: value, expirse: new Date(ttl_ms).getTime() };
                localStorage.setItem(key, JSON.stringify(data));
            },

            get: function (key) {
                var data = JSON.parse(localStorage.getItem(key));
                if (data !== null) {
                    // debugger
                    if (data.expirse != null && data.expirse < new Date().getTime()) {
                        localStorage.removeItem(key);
                    } else {
                        return data.value;
                    }
                }
                return null;
            }
        }

        var data = foowwLocalStorage.get("test");
        if (data != "ok") {
            //开启引导
            introJs().setOption('showProgress', true).start();
            var date = new Date().getTime();

            foowwLocalStorage.set("test", "ok", date + 1000000000);
        }
        
    });
</script>